<?php
$v = $data['svalue'];
?><!doctype html>
<html>
<head>
    <title></title>
    <link rel="stylesheet" type="text/css" href="<?php echo URLPRE;?>static/public/diy/editor.css" />
    <script type="text/javascript" src="<?php echo URLPRE;?>static/public/js/validate.js?v=1.0"></script>
    <script type="text/javascript" src="<?php echo URLPRE;?>static/public/js/ajaxForm.js?v=1.0"></script>
    <script type="text/javascript" src="<?php echo URLPRE;?>static/admin/js/common.js?newversion"></script>
    <script type="text/javascript" src="<?php echo URLPRE;?>static/public/diy/diy_edit.js"></script>
    <!--upload-->
    <link rel="stylesheet" type="text/css" href="<?php echo URLPRE;?>static/public/Lib/webuploader/webuploader.css">
    <script type="text/javascript" src="<?php echo URLPRE;?>static/public/Lib/webuploader/webuploader.js"></script>
    <script type="text/javascript">
        var rowtypedata = [[
            [1, '&nbsp;'],
            [2, '<input style="width:120px;" placeholder="出发地" class="input" name="scity[]" value="" /> <input style="width:120px" placeholder="目的地" class="input" name="ecity[]" value="" />  <input style="width:120px" placeholder="价格" class="input" name="price[]" value="" /> <input style="width:120px" placeholder="出发日期" class="input" name="sdate[]" value=""> <a class="del" onclick="deleterow(this)"></a>'],
        ]];
    </script>
</head>
<body>
<div class="wrap">
    <div class="table_full">
        <div class="h_a"><p>类型：机票链接组 </p></div>
        <form method="post" class="formvalidate" action="<?php echo $form_url;?>" onsubmit="return false">
            <table class="list tab_label" cellpadding="0" cellspacing="1" border="0" id="general_config">
                <tbody>
                <tr>
                    <th style="width:100px">栏目标题</th>
                    <td colspan="2">
                        <p><input class="input rounded valid" type="text" name="e[name]" value="<?php echo $v['e']['name']?>" style="width:120px" /> <span class="g">如：百宝箱</span></p>
                    </td>
                </tr>
                <tr>
                    <th>链接</th>
                    <td colspan="2">
                        <input style="width:120px;" placeholder="出发地" class="input" name="scity[]" value="<?php echo $v['scity'][0]?>" />
                        <input style="width:120px" placeholder="目的地" class="input" name="ecity[]" value="<?php echo $v['ecity'][0]?>" />
                        <input style="width:120px" placeholder="价格" class="input" name="price[]" value="<?php echo $v['price'][0]?>" />
                        <input style="width:120px" placeholder="出发日期" class="input" name="sdate[]" value="<?php echo $v['sdate'][0]?>" />
                    </td>
                </tr>
                <?php
                foreach ((array)$v['scity'] as $k => $vv) {
                    if($k ==0){
                        continue;
                    }
                    ?>
                    <tr>
                        <th>&nbsp;</th>
                        <td colspan="2">
                            <input style="width:120px;" placeholder="出发地" class="input" name="scity[]" value="<?php echo @$v['scity'][$k]?>" />
                            <input style="width:120px" placeholder="目的地" class="input" name="ecity[]" value="<?php echo @$v['ecity'][$k]?>">
                            <input style="width:120px" placeholder="价格" class="input" name="price[]" value="<?php echo @$v['price'][$k]?>" />
                            <input style="width:120px" placeholder="出发日期" class="input" name="sdate[]" value="<?php echo @$v['sdate'][$k]?>">
                            <a class="del" onclick="deleterow(this)"></a>
                        </td>
                    </tr>
                <?php }?>
                <tr>
                    <th>&nbsp;</th>
                    <td colspan="2">
                        <a class="btn_submit" href="javascript:void(0);" onclick="addrow(this,0);">增加</a>
                        <p class="ored">出发地与目的地均为城市名称<br>出发日期格式为2015-01-02</p>
                    </td>
                </tr>
                <tr>
                    <th>&nbsp;</th>
                    <td colspan="2">
                        <button type="submit" class="btn_submit">保存</button>
                    </td>
                </tr>
                </tbody>
            </table>
        </form>
    </div>
</div>
</body>
</html>